package active1.service.impl;

import java.util.List;
import com.ruoyi.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import active1.mapper.JwMembershipActiveMapper;
import active1.domain.JwMembershipActive;
import active1.service.IJwMembershipActiveService;

/**
 * 入团积极分子Service业务层处理
 * 
 * @author ruoyi
 * @date 2024-11-08
 */
@Service
public class JwMembershipActiveServiceImpl implements IJwMembershipActiveService 
{
    @Autowired
    private JwMembershipActiveMapper jwMembershipActiveMapper;

    /**
     * 查询入团积极分子
     * 
     * @param maId 入团积极分子主键
     * @return 入团积极分子
     */
    @Override
    public JwMembershipActive selectJwMembershipActiveByMaId(Long maId)
    {
        return jwMembershipActiveMapper.selectJwMembershipActiveByMaId(maId);
    }

    /**
     * 查询入团积极分子列表
     * 
     * @param jwMembershipActive 入团积极分子
     * @return 入团积极分子
     */
    @Override
    public List<JwMembershipActive> selectJwMembershipActiveList(JwMembershipActive jwMembershipActive)
    {
        return jwMembershipActiveMapper.selectJwMembershipActiveList(jwMembershipActive);
    }

    /**
     * 新增入团积极分子
     * 
     * @param jwMembershipActive 入团积极分子
     * @return 结果
     */
    @Override
    public int insertJwMembershipActive(JwMembershipActive jwMembershipActive)
    {
        return jwMembershipActiveMapper.insertJwMembershipActive(jwMembershipActive);
    }

    /**
     * 修改入团积极分子
     * 
     * @param jwMembershipActive 入团积极分子
     * @return 结果
     */
    @Override
    public int updateJwMembershipActive(JwMembershipActive jwMembershipActive)
    {
        jwMembershipActive.setUpdateTime(DateUtils.getNowDate());
        return jwMembershipActiveMapper.updateJwMembershipActive(jwMembershipActive);
    }

    /**
     * 批量删除入团积极分子
     * 
     * @param maIds 需要删除的入团积极分子主键
     * @return 结果
     */
    @Override
    public int deleteJwMembershipActiveByMaIds(Long[] maIds)
    {
        return jwMembershipActiveMapper.deleteJwMembershipActiveByMaIds(maIds);
    }

    /**
     * 删除入团积极分子信息
     * 
     * @param maId 入团积极分子主键
     * @return 结果
     */
    @Override
    public int deleteJwMembershipActiveByMaId(Long maId)
    {
        return jwMembershipActiveMapper.deleteJwMembershipActiveByMaId(maId);
    }
}
